package com.lanmao.blog.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.lanmao.blog.entity.Tag;
import com.lanmao.blog.mapper.TagMapper;
import com.lanmao.blog.service.TagService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.lanmao.blog.utils.R;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author lanmao
 * @since 2022-03-13
 */
@Service
public class TagServiceImpl extends ServiceImpl<TagMapper, Tag> implements TagService {


    @Override
    public Page<Tag> pageTags(Long current, Long size) {
        Page<Tag> tagPage = new Page<>(current,size);
        QueryWrapper<Tag> wrapper = new QueryWrapper<>();
        baseMapper.selectPage(tagPage,wrapper);
        return tagPage;

    }
}
